Angelscript Interface and Scripting Help File

Preamble --------------------------------------------------------------

    If you're just looking for function prototypes, look in "Objects.txt"
    for member functions (eg Vec2f.SetZero() is found in the Vec2f section)
    or in "Functions.txt" for global functions. The method signatures are
    all listed there, and are guaranteed to be up to date with your
    current version because these files are generated each time the game
    closes by the script runtime.

    The files in interface/ wont necessarily be present or up to date
    until KAG has been opened, a game started, and then closed safely,
    for the script engine to initialise and be able to spit out its
    internal bindings.

    Happy coding :)

Why did you use Angelscript, guys? ------------------------------------

    We selected Angelscript as the language to bind in KAG based on a few
    factors, which any developer that's implemented a scripting language
    should be able to relate to:
        - performance
        - ease of implementation/binding
        - licence
        - syntax
    Angelscript is "fast enough" - it won't outpace LuaJIT but it's also
    no slug either. It was incredibly easy to bind to our existing classes,
    requiring no up front modification to their interfaces. It has a
    nice, permissive zlib licence. Its syntax is very much like C/++,
    which means that when we swap between writing engine code and script
    code we don't have a jarring contrast in how we express something.

General Syntax --------------------------------------------------------

    For help with learning the Angelscript language, see:

        http://www.angelcode.com/angelscript/sdk/docs/manual/doc_script.html

    The language in general is very close to C/++, with the exception
    of object handles being used in place of pointers (and references
    in most instances), no multiple inheritance, and the "native" array
    type ( eg int[] for an array of int ) being more like a vector than
    a C array, because int[] is just syntactic sugar for array<int>.

Specific Interface Files ----------------------------------------------

    These files describe the interface to KAG's engine via Angelscript.
    They are generated by the script runtime on closing each time you
    run the game, so they're up to date with whatever version you have
    installed.

    Objects.txt

        Describes member methods for all registered engine types.

        Find the section beginning with the type you're interested in,
        then search through the list of methods for something that does
        what you want. We don't have documentation getting generated for
        everything yet, but the functions generally have sensible names;
        CPlayer.getBlob() does exactly what you'd expect.

    Functions.txt

        A list of all global function signatures.

    Variables.txt

        A list of all globally accessible variables. Should largely be
        treated as "read only" unless you know what you're doing.

    Hooks.txt

        A list of all hooks called by the engine from arbitrary scripts.
        Will only be called if the script is attached to the a type
        matching the "this" handle at the start of each function - this
        means you can have your sprite onTick and your blob onTick in
        the same file for simplicity with small objects.

    Enums.txt

        A list of all global enumerated types.

    TypeDefs.txt

        Kind of useless as it is, heh.


SCRIPTS DOCUMENTATION ----------------------------------------------

    Available at: https://doc.kag2d.com
    a link is available in the doc/ folder

End -------------------------------------------------------------------
